package coreSimulation;

import java.awt.Container;
import java.awt.Dimension;
import java.awt.GridLayout;

import javax.swing.JFrame;

import queue.QueueGUI;
import dropOffDesk.DeskGUI;

public class MainFrame extends JFrame {

	/**
	 * Main GUI Window containing both queue and desks
	 */
	private static final long serialVersionUID = 4044556012685906713L;

	public MainFrame(QueueGUI queueGUI, DeskGUI deskGUI) {
		this.setDefaultCloseOperation(DO_NOTHING_ON_CLOSE);

		// Create a two column layout
		GridLayout gl = new GridLayout(1, 2);
		Container container = this.getContentPane();

		container.setLayout(gl);
		// add the queue to the left column
		container.add(queueGUI);
		// add the JPanel containin the drop of desk(s) to the right panel
		container.add(deskGUI);
		this.setSize(new Dimension(1100, 1000));
		this.validate();

	}

}
